package com.ruoyi.wcf.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.wcf.mapper.WcfDisposeOrderFrequencyMapper;
import com.ruoyi.wcf.domain.WcfDisposeOrderFrequency;
import com.ruoyi.wcf.service.IWcfDisposeOrderFrequencyService;

/**
 * 客户管理-下单频次设置Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-04-02
 */
@Service
public class WcfDisposeOrderFrequencyServiceImpl implements IWcfDisposeOrderFrequencyService 
{
    @Autowired
    private WcfDisposeOrderFrequencyMapper wcfDisposeOrderFrequencyMapper;

    /**
     * 查询客户管理-下单频次设置
     * 
     * @param id 客户管理-下单频次设置主键
     * @return 客户管理-下单频次设置
     */
    @Override
    public WcfDisposeOrderFrequency selectWcfDisposeOrderFrequencyById(Long id)
    {
        return wcfDisposeOrderFrequencyMapper.selectWcfDisposeOrderFrequencyById(id);
    }

    /**
     * 查询客户管理-下单频次设置列表
     * 
     * @param wcfDisposeOrderFrequency 客户管理-下单频次设置
     * @return 客户管理-下单频次设置
     */
    @Override
    public List<WcfDisposeOrderFrequency> selectWcfDisposeOrderFrequencyList(WcfDisposeOrderFrequency wcfDisposeOrderFrequency)
    {
        return wcfDisposeOrderFrequencyMapper.selectWcfDisposeOrderFrequencyList(wcfDisposeOrderFrequency);
    }

    /**
     * 新增客户管理-下单频次设置
     * 
     * @param wcfDisposeOrderFrequency 客户管理-下单频次设置
     * @return 结果
     */
    @Override
    public int insertWcfDisposeOrderFrequency(WcfDisposeOrderFrequency wcfDisposeOrderFrequency)
    {
        wcfDisposeOrderFrequency.setCreateTime(DateUtils.getNowDate());
        return wcfDisposeOrderFrequencyMapper.insertWcfDisposeOrderFrequency(wcfDisposeOrderFrequency);
    }

    /**
     * 修改客户管理-下单频次设置
     * 
     * @param wcfDisposeOrderFrequency 客户管理-下单频次设置
     * @return 结果
     */
    @Override
    public int updateWcfDisposeOrderFrequency(WcfDisposeOrderFrequency wcfDisposeOrderFrequency)
    {
        return wcfDisposeOrderFrequencyMapper.updateWcfDisposeOrderFrequency(wcfDisposeOrderFrequency);
    }

    /**
     * 批量删除客户管理-下单频次设置
     * 
     * @param ids 需要删除的客户管理-下单频次设置主键
     * @return 结果
     */
    @Override
    public int deleteWcfDisposeOrderFrequencyByIds(Long[] ids)
    {
        return wcfDisposeOrderFrequencyMapper.deleteWcfDisposeOrderFrequencyByIds(ids);
    }

    /**
     * 删除客户管理-下单频次设置信息
     * 
     * @param id 客户管理-下单频次设置主键
     * @return 结果
     */
    @Override
    public int deleteWcfDisposeOrderFrequencyById(Long id)
    {
        return wcfDisposeOrderFrequencyMapper.deleteWcfDisposeOrderFrequencyById(id);
    }
}
